package com.woniu.service.Impl.backpage;


import com.woniu.dao.backpage.OrdersDetailsDao;
import com.woniu.entity.OrdersDetails;
import com.woniu.service.backpage.IOrdersDetailsService;
import com.woniu.util.ResData;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.List;

/**
 * 订单明细表实现类
 * @author 任楷锐
 * @data 2023/3/7 17:38
 */
@Service
public class OrdersDetailsServiceImpl implements IOrdersDetailsService {
    @Autowired
    private OrdersDetailsDao ordersDetailsDao;

    /*查询所有的订单明细*/
    @Override
    public ResData<?> getAllOrdersDetails(String ordersId) {
        List<OrdersDetails> ordersDetailsList = ordersDetailsDao.findAllOrdersDetails(ordersId);
        return new ResData<>().ok(ordersDetailsList);
    }
}
